* ReadMe file for the computer program to replicate the results in "Spatial Interactions" 
(by Jun Sung Kim, Eleonora Patacchini, Pierre Picard, and Yves Zenou)

Add Health Files 

Wave 1 In-Home Survey
	Main sample, used for control variables and outcomes
Wave 1 Friends Survey
	Used to identify student peers
Wave 1 School-Information
	Used to identify religious schools
	
These files can be accessed by entering into a restricted-use data agreement with UNC Population Center:
http://www.cpc.unc.edu/projects/addhealth/data/restricteduse

Details on the selection and coding of the relevant variables are shown in the Stata do-file, rawdata_cleaning.do. 
This do-file describes how to get from the original Wave I data to the datasets that we used to create social interaction networks and other relevant data for estimation and policy analyses.
Structural estimation and policy simulation have been completed using Python, while regressions are done using Stata.

We detail below how to get to the results of the paper table by table.

Final data construction
- rawdata_cleaning.do
- net_construction.py

Tables 1:
- compare_samples.py

Tables 2:
- soc_by_pairs.py

Table 3:
- fwm_schools_4to50.py (or 150)
- Estimation_schools_4to50.py (or 150)
- BSE_schools_4to50.py (or 150)

Table 4:
- Obs_and_opt_soc_int.py

Table 5--7:
- Opt_network_data_construction.py
- policy_regressions.do

Table 8:
- Policy_level_for_opt.py

Table 9:
- Compare_policy_netsubsidy_Bsig.py
- Compare_policy_indsubsidy_Bsig.py
- Compare_policy_pairsubsidy_Bsig.py
- Compare_policy_netsubsidy_Btau.py
- Compare_policy_indsubsidy_Btau.py
- Compare_policy_pairsubsidy_Btau.py